home *** CD-ROM | disk | FTP | other *** search
/ Almathera Ten Pack 3: CDPD 3 / Almathera Ten on Ten - Disc 3: CDPD3.iso / scope / 026-050 / scopedisk27 / rzszmdm / amiga.doc < prev    next >
Text File  |  1995-03-18  |  13KB  |  331 lines

  1.  
  2.                  Amiga zmodem
  3.                  ------------
  4.  
  5.  
  6.  
  7.  Zmodem is a file transfer protocol which will enable you to transmit files
  8. between different computers. In fact the zmodem programs can transfer files
  9. using several popular protocols: Xmodem,Ymodem and Zmodem. To find out about
  10. all the features of the zmodem programs, be sure to read rz.doc and sz.doc,
  11. because I will only mention the features specific to the amiga version here.
  12.  Please note that some features of UNIX zmodem are not supported. This is
  13. mentioned in the zmodem '.doc' files.
  14.  
  15.  The reason I ported these programs to the Amiga, is that Zmodem file transfers
  16. are very fast. When I was using Kermit the throughput I got was about 30
  17. characters/second (1200 baud modem, going through packet switching network), now
  18. with Amiga zmodem I get at least 100 characters/second. Your mileage may
  19. vary, but I'm pretty sure you'll get a significant speedup if you've been
  20. using either Kermit or Xmodem. Enjoy!
  21.  
  22.             CONTENTS
  23.  
  24.          I     Installing zmodem
  25.          II  Quick explanation on transferring files
  26.          III Cooperating communications programs
  27.          IV  Amiga specific features
  28.          V     Caveats,bugs and "features" (sigh!)
  29.  
  30.  
  31.  I/ Installing zmodem
  32.  
  33.  To install UNIX zmodem rename the file 'makefile.unix' as 'makefile'. Then
  34. type 'make system'. Where system is the version of UNIX you are using, and is
  35. one of the following:
  36.  
  37.     sysv        for SYSTEM 5 Unix
  38.     xenix        for SYSTEM 3/5 Xenix
  39.     x386        for 386 Xenix
  40.     bsd        for Berkeley 4.x BSD and Ultrix
  41.  
  42.  To install Amiga zmodem just uudecode the files rz.uu and sz.uu, and you're
  43. ready to go.
  44.  
  45.  
  46.  
  47.  II/ Quick explanation on transferring files
  48.  
  49.  Sending files from UNIX to the AMIGA using zmodem:
  50.  
  51.                 (log in on UNIX machine)
  52.                 (make sure preferences has the correct serial
  53.                  setup, or that you have the zmodem.init file
  54.                  correctly set up, or a cooperating
  55.                  comm. program running)
  56.  
  57.     sz file1 file2 ...        (type this on your UNIX system)
  58.                 (exit your communications program)
  59.     rz                (type this on the Amiga)
  60.  
  61.  Sending files from the Amiga to UNIX using zmodem:
  62.  
  63.                 (log in on UNIX machine)
  64.                 (if your comm. program doesn't cooperate
  65.                  exit it.)
  66.                 (make sure preferences has the correct serial
  67.                  setup, or that you have the zmodem.init file
  68.                  correctly set up, or a cooperating
  69.                  comm. program running)
  70.     sz file1 file2 ...        (type this on the Amiga, Amiga sz automatically
  71.                  fires up UNIX rz)
  72.  
  73.  
  74.  
  75.  III/ Cooperating communications programs
  76.  
  77.  There are many different protocols for transferring files from one
  78. computer to another. So many in fact, that almost no terminal program
  79. can support them all! So my idea was to provide a stand along program
  80. that would work with a terminal program. This would allow more efficient
  81. use of the computer's memory because the file transfer program would only
  82. be in memory when it was actually being used. Also authors of terminal
  83. programs could concentrate their efforts on other issues. The unique
  84. features of the Amiga make this idea possible.
  85.  
  86.  Zmodem can cooperate with other programs using the serial port. For this
  87. to work, the other program has to do two things:
  88.  
  89.     - Open the serial port in shared mode
  90.     - suspend it's read operations while zmodem is transferring files
  91.  
  92.  Actually it's also a good idea to suspend write operations also, because
  93. accidental keyboard input could interfere with the file transfer.
  94.  
  95.  An example of a cooperating communications program should be the new
  96. version of VT100 (r. 2.9).
  97.  
  98.  If your comm. program doesn't cooperate, you can still be use Amiga zmodem.
  99. Just exit your non-cooperating comm. program before running zmodem. If your
  100. modem drops the line when you exit (ie. when DTR goes down), just use the
  101. built in terminal mode in zmodem ('-T' switch).
  102.  
  103.  
  104.  
  105.  
  106.  IV/ Amiga specific features
  107.  
  108.   a/Initializing the serial port
  109.  
  110.  A new amiga specific switch '-I' has been added to allow initialization of
  111. the serial port parameters. If this switch is used, zmodem will look
  112. for a file called 'zmodem.init', which can either be in the current
  113. directory, or the 'S:' directory.
  114.  
  115.  The file has the following format: 1 line composed of
  116.  
  117. --------------------
  118. baudrate nps
  119. --------------------
  120.  
  121.  Where 'baudrate' is a number between 110 and 29,200 representing the
  122. transmission speed to be used.
  123.  
  124.  Where 'n' is the number of bits per character (7 or 8).
  125.  
  126.  Where 'p' is the parity to be used. The value of 'p' will be
  127. one of: 'N','E','O' (standing for None,Even and Odd respectively)
  128.  
  129.  And where 's' is the number of stop bits (between 0 and 2).
  130.  
  131.  So if you want your file transfers to take place at 2400 bits per second,
  132. 8 bits per character, no parity and 1 stop bit, you would place the following
  133. line in your zmodem.init file:
  134.  
  135. 2400 8N1
  136.  
  137.  These parameters have to be on the first line of the file, no other lines
  138. will be examined. Also, if the zmodem.init file is not found, then the '-I'
  139. switch will be ignored.
  140.  
  141.  If no '-I' is given on the command line, then default parameters are
  142. used. This means that if a cooperating program using the serial port is in
  143. use, then the default parameters are the ones set up by that program.
  144. Otherwise the default parameters are the ones you have specified using
  145. preferences. If you use preferences to specify the serial parameters you must
  146. disenable xON/xOFF handshaking for Xmodem and Ymodem transfers to work
  147. correctly.
  148.  
  149.  If the terminal program you are using doesn't cooperate, then zmodem will
  150. tell you that it can't open the serial port for transferring files, and
  151. abort its execution. In that case stop the terminal program before
  152. running zmodem.
  153.  
  154.  When a cooperating terminal program is running, it isn't possible to
  155. use the '-I' option. The parameters used will be automatically those
  156. set up by the terminal program. If you try the '-I' option under these
  157. conditions zmodem will print an error message and abort.
  158.  
  159.   b/ Aborting file transfers
  160.  
  161.  Zmodem can be aborted at any time by clicking in the close box of the zmodem
  162. window.
  163.  
  164.   c/ Files to large for space remaining on disk
  165.  
  166.  Amiga zmodem will detect if the incoming file is too large to fit on the
  167. current disk. The files that won't fit are skipped. Zmodem only checks the
  168. space remaining at the start of each file, so you may still get full
  169. disks, if you use up some of the remaining free space while the file
  170. transfer is going on (hurrah for multi-tasking:-). This feature can be
  171. disabled with the '-n' option, which is useful if the destination device
  172. happens to be RAM:. That's because RAM:, is always full, so you couldn't
  173. receive any files on it at all.
  174.  
  175.   d/ Ymodem file transfers
  176.  
  177.  With the UNIX version of zmodem, Ymodem transfers were requested by calling
  178. zmodem using the names sb or rb (send batch or receive batch). But on
  179. the amiga this isn't practical, since this would require keeping several
  180. copies of zmodem, with only the name being different. To remedy this
  181. situation, the '-B' switch was added, this lets you use the Ymodem protocol
  182. and have only one copy of zmodem around.
  183.  
  184. examples: sz -B f1 f2 f3
  185.       rz -B
  186.  
  187.  e/ Xmodem file transfers
  188.  
  189.  To send with the xmodem protocol use: 'sz -X file', and for receiving
  190. 'rz file'. If you give a file name to rz, the file transfer will
  191. be done using Xmodem protocol, even if on the sending end you specified
  192. a zmodem transfer, so watch out!
  193.  
  194.  
  195.  f/ Maintaining file protection bits
  196.  
  197.  When transferring between UNIX and the Amiga, the file protection
  198. bits are also transfered. When sending from the amiga to UNIX the bits 'rwe'
  199. are translated into the 'rwe' for user bits on UNIX. UNIX doesn't have a
  200. 'd' bit, but if you don't have write permission rm will ask for permission
  201. to over-ride protection (ie. you can't delete it accidentally). So the UNIX
  202.  'w' bit is translated into the Amiga 'wd' bits. That is to say if the UNIX
  203. file doesn't have write permission the Amiga file won't have write or delete
  204. permission. The transmission of the file protection bits can be overriden,
  205. with the '-m' option. In this case the transmitted files will have the
  206. default file protection bits.
  207.  
  208.  
  209.  g/ Automatic ASCII transfer mode
  210.  
  211.  To be able to transfer raw binary files zmodem needs 8 bits per
  212. character. If the serial port parameters aren't set up this way zmodem
  213. automatically uses it's ASCII transfer mode. The transfer mode being used
  214. by zmodem is printed when the file transfer starts. You should transfer
  215. files using binary mode for files you want transferred without any changes
  216. made to them. The ASCII mode will try to adapt the incoming file to
  217. amiga text file conventions ( all CR LF sequences replaced by LF ).
  218.  
  219.  h/ Maintaining file dates
  220.  
  221.  One of the features of Zmodem, is that it keeps the same file-modification
  222. date on the source and destination files. But due to the format used to
  223. transmit the date, zmodem has to know what time zone you are in, relative
  224. to the GM (Greenwich Meridian). I know this is strange, but that's the
  225. way zmodem works. This time zone difference can also change during the year,
  226. because GMT doesn't have any daylight savings time! Anyway, if you want
  227. the file dates maintained you must add an extra number (this is an option)
  228. into your zmodem.init file which specifies the difference between your local
  229. time zone and GMT.
  230.  
  231.  In this case the format of the zmodem.init file becomes:
  232.  
  233. ---------------------
  234. baudrate nps gmt_diff
  235. ---------------------
  236.  
  237. my zmodem.init file is
  238.  
  239.   1200 8N1 +2  (this is for europe)
  240.  
  241. If you are in the EST time zone, you will probably set gmt_diff to -4.
  242. If you don't care about the file-modification date on the transfered file,
  243. the easiest thing to do is just leave gmt_diff out. Then the transfered
  244. file's date will be set by zmodem to the current date.
  245.  
  246.  
  247.  i/ Terminal mode
  248.  
  249.  A very primitive terminal mode has been provided, to enable those with "smart"
  250. modems (ie. ones that drop phone connection when DTR goes down) to use zmodem.
  251. Use the terminal mode to log in, and then click on the close box of the zmodem
  252. window, the file transfer requested will follow automatically. Once the file
  253. transfer is completed, zmodem will re-enter the terminal mode, permitting
  254. you to log out cleanly.
  255.  
  256.  
  257.  
  258.  V/ Caveats,bugs and "features" (sigh!)
  259.  
  260.  If Ymodem protocol is used by the sending program, and the receiving
  261. program is using Xmodem, the first file will be transferred, but the
  262. sending Ymodem program will not exit correctly.
  263.  
  264. example: sz foo        <-- starts out with Zmodem, steps down to Ymodem
  265.      rz foo        <-- uses Xmodem because file name is given
  266.  
  267.  the correct sequences would be:
  268.  
  269.   sz foo bar toto    <-- Zmodem transfer
  270.   rz
  271.  
  272.  or
  273.   sz -B foo bar toto    <-- Batch Ymodem transfer
  274.   rz -B
  275. or
  276.   sz -X foo       <-- Xmodem transfer
  277.   rz foo
  278.  
  279.  
  280.  When using the '-f' option of sz (send whole pathname) the directories in
  281. the path will not be created. If one of the directories in the pathname
  282. doesn't exist, the file will not be sent. A newer version of UNIX rz will
  283. handle the creation of the directories. Amiga rz still doesn't though.
  284.  
  285.  If you are using parity, amiga zmodem won't accept any characters without
  286. the parity bit correctly set. Many UNIX hosts won't set the parity bit
  287. correctly on output even if they are set up to check parity on input.
  288. I recommend  avoiding using parity with zmodem whenever possible.
  289. It limits you to transferring just text files anyway.
  290.  
  291.  Sz's -n (send file iff newer) and -N (send file if newer or longer) options
  292. are not implemented in Unix or Amiga zmodem.
  293.  
  294.  Sz's -r (resume interupted file transfer) option isn't implemented in this
  295. version of UNIX zmodem, or Amiga zmodem.
  296.  
  297.  Sz's -y (overwrite existing files with same name) option is pretty useles
  298. with the UNIX and Amiga versions of zmodem, because this is already the
  299. default behavior.
  300.  
  301.  I haven't been able to test Amiga zmodem at speeds other than 1200 bps.
  302. I hope that zmodem will be reasonably efficient and bug free using
  303. different speeds. If rz can't keep up at higher speeds, it may be
  304. necessary to increase the size of the serial buffer using preferences.
  305. If you increase the buffer size, don't use the '-I' option. With the
  306. '-I' option the buffer size is always the same no matter what you choose
  307. in preferences (1024 bytes).
  308.  
  309. ---------------------------------------------------------------------------
  310.  
  311.  Many thanks to Chuck Forsberg who wrote the UNIX version of zmodem, and on
  312. which Amiga zmodem is based. Thanks also go to all the good people who
  313. have helped to make the amiga the useful and successful machine it is
  314. today. The people from Los Gatos, and CATS. And also those who have
  315. provided the public domain tools that have made this program possible,
  316. Matt Dillon for DME and the shell, Steve Drew for his work on the shell,
  317. Dave Wecker and Tony Sumrall for the vt100 terminal program, Peter Da Silva
  318. for Browser, and all the other PD authors who's programs I've used. And of
  319. course Fred Fish, for making all the PD software available.
  320.  
  321.  Please send bug reports and/or bug corrections to me:
  322.  
  323.  
  324.   Frank Anthes-Harper
  325.   72, Le Puech des Bruyeres
  326.   Av. de Mr. Teste
  327.   34070 Montpellier
  328.   France
  329.  
  330. Usenet:  ...!ucbvax!decvax!uunet!mcvax!inria!geocub!anthes
  331.